
import React from 'react'

import {Baoju} from '../../components/baoju'
import A from 'assets/images/my/blackadd.@2x.png'
import {useState} from 'react'
// function getem(e){
//     console.log(e.target.files,e.target.value)
// }

const Bao =function(props){
    // const [list,setlist]=useState(0)
    console.log(props.list)
    return (
        <>
            <Baoju leng={props.leng} heig={props.heig}>
                <div className='reallyContainer'>
                <h2>举报</h2>
                <input className='inputtext' type="text" name="" placeholder='请输入你要举报的名称'/>
                <p>举报原因</p>
                <textarea name="" id=""></textarea>
                <p className='last'>相关截图：</p>
               <div className='containerImg'>
                    <input className='inputfile' type='file' onChange={(e)=>props.changeImage(e)}/>
                        <div className='fdiv'>
                            <img src={A} alt=""/>
                        </div>
                        {
                            props.list.map((value,index)=>{
                                return <img className='baojuimg' src={value} key={index} alt=""/>
                            })
                        }
                        {
                            props.leng===0||props.heig>0?<div className='nuuull'></div>:''
                        }
               </div>

                

                <div className='ldiv'>
                    <button onClick={props.tijiao}>提交</button>
                </div>
                </div>
              
            </Baoju>
        </>
    )
}
export default Bao
